const router = require('koa-router')()
const {getMenu, getMenuAll} = require('../../controller/menu')

router.prefix('/api/menu')

router.get('/menu', async (ctx, next) => {
  ctx.body = await getMenu(ctx)
})

router.get('/menu/all', async (ctx, next) => {
  ctx.body = await getMenuAll()
})

module.exports = router
